# Maintainer: Alexander F. Rødseth <xyproto@archlinux.org>
# Contributor: Jaroslav Lichtblau <dragonlord@aur.archlinux.org>
# Contributor: Allan McRae <allan@archlinux.org>
# Contributor: David Moore <davidm@sjsoft.com>

pkgname=python-simplejson
pkgver=3.19.1
pkgrel=2
pkgdesc='Simple, fast and extensible JSON decoder/encoder'
license=(MIT)
arch=(loong64 x86_64)
url='https://github.com/simplejson/simplejson'
depends=(python)
makedepends=(git python-setuptools)
checkdepends=(python-nose python-pytest-runner)
source=("git+$url#commit=aeb63ee451732b1e77008c28153380d8dd0fda20") # tag: v3.19.1
b2sums=('SKIP')

build() {
  cd simplejson
  python setup.py build
}

check() {
  nosetests -w simplejson
}

package_python-simplejson() {
  cd simplejson
  python setup.py install --root="$pkgdir"
  install -Dm644 ../simplejson/LICENSE.txt \
    "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}
